import request from '@/utils/request';

// 获取用户信息
export function getInfo() {
    return request({
        url: '/system/user/getInfo',
        method: 'get'
    })
}

//修改用户
export function updateUser(data) {
    return request({
        url: '/system/user/profile/updateUser',
        method: 'post',
        data
    })
}

// 通过手机号码发送短信验证码
export function getSmsByPhone(query) {
    return request({
        url: '/auth/smsByPhone',
        method: 'get',
        headers: {
            isToken: true
        },
        params: query
    })
}


// 通过手机号码发送短信验证码
export function getSmsVerify(query) {
    return request({
        url: '/auth/smsVerify',
        method: 'get',
        headers: {
            isToken: true
        },
        params: query
    })
}

// 修改密码
export function editPassword(query) {
    return request({
        url: '/system/user/profile/editPwd',
        method: 'put',
        params: query
    })
}
